package com.service.impl;

import com.dao.AddressDao;
import com.dao.impl.AddressDaoImpl;
import com.pojo.TbAddress;
import com.service.AddressService;

import java.util.List;

public class AddressServiceImpl implements AddressService {

    private AddressDao addressDao=new AddressDaoImpl();

    @Override
    public List<TbAddress> findAllAddresByUid(long uid) {

        return addressDao.findAllAddresByUid(uid);
    }

    @Override
    public void createAddress(TbAddress tbAddress) {
        addressDao.createAddress(tbAddress);

    }

    @Override
    public List<TbAddress> showAddress(Long id) {

        return  addressDao.showAddress(id);
    }

    @Override
    public TbAddress selAddress(int id) {
        return addressDao.selAddress(id);
    }

    @Override
    public void update(TbAddress tbAddress) {

        addressDao.update(tbAddress);
    }

    @Override
    public void delAdd(int aid) {

        addressDao.delAdd(aid);
    }
}
